<%@ page import="java.util.List" %>
<%@ page import="com.foreknow.bean.Guestbook" %><%--
  Created by IntelliJ IDEA.
  User: hp
  Date: 2020/12/28
  Time: 15:02
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@page import="java.util.List"%>
<%@page import="com.foreknow.bean.Guestbook"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%
    String path = request.getContextPath();//获取的工程的application context
    request.setAttribute("path",path);//将获取到的路径保存到request中
%>

<%@taglib prefix="pager" uri="http://blog.zjjlive.net/zjjlive/tags/pager" %>
<html>
<link href="https://cdn.bootcss.com/bootstrap/3.3.7/css/bootstrap.min.css" rel="stylesheet">
<head>
<body>
<div>
    username:${sessionScope.admin.username}
    <table class="table table-hover">
        <tr>
            <td>编号</td>
            <td>姓名</td>
            <td>电话号码</td>
            <td>邮箱</td>
            <td>标题</td>
            <td>内容</td>
            <tb>创建时间</tb>
            <td>操作</td>
        </tr>
        <c:forEach var="gb" items="${list}" varStatus="status">
            <tr>
                <td>${gb.id}</td>
                <td>${gb.name}</td>
                <td>${gb.phone}</td>
                <td>${gb.email}</td>
                <td>${gb.title}</td>
                <td>${gb.content}</td>
                <td>${gb.createdTime}</td>
                <td>
                    <a href="/foreknow_webdemo/user/manager?id=${gb.id}&q=delete" class="btn btn-danger">删除</a>
                    <a href="" class="btn btn-primary">修改</a>
                </td>
            </tr>
        </c:forEach>

    </table>
    <div>
        <pager:pager pageNo="${requestScope.pageNo}" recordCount="${requestScope.total}" pageSize="${initParam.pageSize}" url="${path}/user/manager?q=list"/>
    </div>

</div>
</body>
<%--    <title>Title</title>--%>
<%--&lt;%&ndash;    Bootstrap core CSS &ndash;%&gt;--%>
<%--    <link href="https://cdn.bootcss.com/bootstrap/3.3.7/css/bootstrap.min.css" rel="stylesheet">--%>



</head>
<body>

    <p>要显示留言的数据</p>

</body>
</html>
